﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace XiaoYuStock.Core
{
   public class ConvertHelper
    {

       /// <summary>
       /// 
       /// </summary>
       /// <param name="v"></param>
       /// <returns></returns>
       public static decimal ToDecimal(string v)
       {
           decimal result = 0;
           decimal.TryParse(v,out result);
           return result;
       }

       /// <summary>
       /// 
       /// </summary>
       /// <param name="v"></param>
       /// <returns></returns>
       public static int ToInt(string v)
       {
           int result = 0;
           int.TryParse(v, out result);
           return result;
       }
    }
}
